#通常情况下只需修改 TARGET  OBJ  和 TARGET X 的生成规则即可

TARGET1:=shareMemTestServer
TARGET2:=shareMemTestClient
OBJ1:=shareMemTestServer.o
OBJ2:=shareMemTestClient.o
TARGET:=$(TARGET1) $(TARGET2)
OBJ:=$(OBJ1) $(OBJ2)

all:$(TARGET) public_target_install 
.PHONY:clean
clean:public_target_clean public_clean

CURR_DIR := $(shell pwd)
ROOT_DIR := $(subst /ipc,/ipc ,$(CURR_DIR))
ROOT_DIR := $(word 1,$(ROOT_DIR))

include $(ROOT_DIR)/make.defines
include $(ROOT_DIR)/make.rules
-include $(OBJ:.o=.d)

CFLAGS += -I$(ROOT_DIR)/include

$(TARGET1):$(OBJ1)
	$(CC) -o $@ $< -Wl,-rpath, -L$(COMMON_LIB_PATH) $(COMMON_LIB)
	
$(TARGET2):$(OBJ2)
	$(CC) -o $@ $< -Wl,-rpath, -L$(COMMON_LIB_PATH) $(COMMON_LIB)